home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 6424 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  2.6 KB

  1. Path: goanna.cs.rmit.EDU.AU!not-for-mail
  2. From: ok@goanna.cs.rmit.EDU.AU (Richard A. O'Keefe)
  3. Newsgroups: comp.lang.ada,comp.lang.c++,comp.lang.c,comp.lang.modula3,comp.lang.modula2
  4. Subject: Re: Hungarian notation - whoops!
  5. Date: 8 Feb 1996 16:19:35 +1100
  6. Organization: Comp Sci, RMIT, Melbourne, Australia
  7. Message-ID: <4fc157$jsf@goanna.cs.rmit.EDU.AU>
  8. References: <30C40F77.53B5@swsbbs.com> <Pine.HPP.3.91.960124153551.24374C-100000@zeezrom.cs.byu.edu> <4e7ifl$et3@goanna.cs.rmit.EDU.AU> <Pine.HPP.3.91.960129133429.8419C-100000@foggy.cs.byu.edu> <4em29qINN39r@keats.ugrad.cs.ubc.ca> <Pine.HPP.3.91.960201015336.17360C-100000@clear.cs.byu.edu> <4f41vf$g8j@goanna.cs.rmit.EDU.AU> <Pine.HPP.3.91.960205124102.18647E-100000@warm.cs.byu.edu>
  9. NNTP-Posting-Host: goanna.cs.rmit.edu.au
  10. NNTP-Posting-User: ok
  11. X-Newsreader: NN version 6.5.0 #0 (NOV)
  12.  
  13. Douglas Evan Cook <cookd@cs.byu.edu> writes:
  14. >Actually, if you consider the following as an ADT, it does, and it makes 
  15. >things very nice:
  16. >TYPE INT16:
  17. >  Holds numbers from -32768 to 32767, stored in 16 bits, little-endian.
  18.  
  19. How often do I have to say this?
  20.  
  21. - ADT means >>>>>>>>>>>>>>>>ABSTRACT<<<<<<<<<<<<<<<< data type
  22. - bit size is CONCRETE
  23. - endianness is CONCRETE
  24.  
  25.  
  26. >Then, when porting to a different platform, you just do whatever it takes 
  27. >to define INT16 to match the spec.
  28.  
  29. How often do I have to say _this_?
  30.  
  31. - There are two (16Mb, recent) computers on my desk.  (One will be going
  32.   away soon.)
  33. - There are two other computers in this office.  One needs repair, but
  34.   has the nicest keyboard I've ever used, and the other needs a 240 volt
  35.   to 110 volt transformer which I loaned to a friend.
  36. - I have accounts on three (large, recent) multi-user machines in this
  37.   department, and am posting from one of them at the moment.
  38.  
  39. *NONE* of these machines can support a 16-bit little-endian integer type.
  40.  
  41. I _could_ get an account on a supercomputer if I wanted to.  I have also
  42. used a couple of mainframes.  None of them can support a 16-bit little-
  43. endian integer type either.  One of the mainframes was not 2s complement
  44. (it was sign-and-magnitude; I still think having a negative number whose
  45. absolute value can't be represented is _silly_).  That kind of mainframe
  46. is still made and still used and still appropriate.,
  47.  
  48. Abstract data types are where you HIDE the implementation details
  49. so that your program doesn't depend on the implementation details
  50. so that your program will work on a machine with different implementation
  51. details.
  52.  
  53. -- 
  54. "conventional orthography is ... a near optimal system for the
  55.  lexical representation of English words." Chomsky & Halle, S.P.E.
  56. Richard A. O'Keefe; http://www.cs.rmit.edu.au/~ok; RMIT Comp.Sci.
  57.